﻿<%@ Page Language="C#" MasterPageFile="~/System/MasterPageTra.master" AutoEventWireup="true"
    CodeFile="TraConfirmGoods.aspx.cs" Inherits="Hospital_TraConfirmGoods" Title="入库清单列表" %>

<%@ Register Src="../System/DbPageFlip.ascx" TagName="DbPageFlip" TagPrefix="uc1" %>
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" runat="Server">

    <script language="javascript">

        //  window.alert("11");
        function SelectAll() {
            var i;
            var a = document.getElementsByName('chk');
            for (i = 0; i < a.length; i++) {
                a[i].checked = true;
            }
        }
        function ClearAll() {
            var i;
            var a = document.getElementsByName('chk');

            for (i = 0; i < a.length; i++) {
                a[i].checked = false;
            }
        }

        function CheckOthers() {
            var i;
            var a = document.getElementsByName('chk');

            for (i = 0; i < a.length; i++) {

                if (a[i].checked != true) {
                    a[i].checked = true;
                }
                else {
                    a[i].checked = false;
                }
            }

        }
       
        
      
        
        
    </script>

    <script language="vbscript">
    	Function CheckForm1()
		Dim bolSubmit
		bolSubmit = True
		Dim txtInput
		dim i
		 
		Set txtInput = document.all("tabData1").all.tags("Input")

		'msgbox "“" 
	    For i = 0 To txtInput.length - 1
		    If IsNull(txtInput(i).getAttribute("NumericOnly")) = False Then
			    If Len(txtInput(i).value) > 0 Then
				    If IsNumeric(txtInput(i).value) = False Then
					    msgbox "“" & txtInput(i).getAttribute("NumericOnly") & "”必须输入数字！",16,"修改档案"
					    txtInput(i).select()
					    txtInput(i).focus()
					    bolSubmit = False
					    CheckForm1 = False
					    Exit For
				    End If
			    End If
		    End If
		    If IsNull(txtInput(i).getAttribute("NotNull")) = False Then
			    If Len(Trim(txtInput(i).value)) = 0 Then
				    msgbox "“" & txtInput(i).getAttribute("NotNull") & "”必须输入！",16,"警告"
				    txtInput(i).select()
				    txtInput(i).focus()
				    bolSubmit = False
				    CheckForm1 = False
				    Exit For
			    End If
		    End If
		    If IsNull(txtInput(i).getAttribute("DateTimeOnly")) = False Then
			    If Len(txtInput(i).value) > 0 Then
				    If IsDate(txtInput(i).value) = False Then
					    msgbox "“" & txtInput(i).getAttribute("DateTimeOnly") & "”必须输入日期！",16,"修改档案"
					    txtInput(i).select()
					    txtInput(i).focus()
					    bolSubmit = False
					    CheckForm1 = False
					    Exit For
				    End If
			    End If
		    End If

		    If IsNull(txtInput(i).getAttribute("InvertedComma")) = False Then
			    If Len(txtInput(i).value) > 0 Then
				    If InStr (txtInput(i).value,"'") >0Then
					    msgbox "“" & txtInput(i).getAttribute("InvertedComma") & "”含有非法字符 ' 请重新输入！",16,"修改档案"
					    txtInput(i).select()
					    txtInput(i).focus()
					    bolSubmit = False
					    CheckForm1 = False
					    Exit For
				    End If
			    End If
		    End If
	    Next
		
	End Function
	
    </script>

    <script language="vbscript" src="../Common/yz.vbs"></script>

    <script language="javascript" src="../common/javascript/calendar.js" type="text/javascript">        function Button1_onclick() {

        }

    </script>

    <table width="98%" border="0" align="center" cellpadding="0" cellspacing="0">
        <tr>
            <td style="width: 4px">
                <img src="../images/intro_left.gif" width="4" height="34">
            </td>
            <td class="intro_wordbg">
                入库管理
            </td>
            <td background="../images/intro_bg.gif">
                <img src="../images/intro_right.jpg" width="118" height="34">
            </td>
        </tr>
    </table>
    <table width="99%" border="0" align="center" cellpadding="0" cellspacing="0">
        <tr>
            <td>
                <table id="tabData1" width="99%" border="1">
                    <tr>
                        <td align="right">
                            药品流水号：
                        </td>
                        <td>
                            <asp:TextBox ID="txtGoodsId" runat="server" Width="187px" NumericOnly="药品流水号"></asp:TextBox>
                        </td>
                        <td align="right">
                            通用名：
                        </td>
                        <td style="height: 26px; width: 304px;">
                            <asp:TextBox ID="txtProductName" runat="server" InvertedComma="用户名称" Width="187px"></asp:TextBox>
                        </td>
                    </tr>
                    <tr>
                        <td align="right">
                            生产企业：
                        </td>
                        <td>
                            <asp:TextBox ID="textCompanyName_SC" runat="server" InvertedComma="用户编码" Width="187px"></asp:TextBox>
                        </td>
                        <td align="right">
                            生产企业编号：
                        </td>
                        <td style="height: 26px; width: 304px;">
                            <asp:TextBox ID="textCompanyName_usercoder_sc" runat="server" InvertedComma="生产企业编号"
                                Width="187px"></asp:TextBox>
                        </td>
                    </tr>
                    <tr>
                        <td align="right">
                            配送企业：
                        </td>
                        <td align="left">
                            <asp:TextBox ID="TextCompanyName_PS" runat="server" InvertedComma="单位名称" Width="187px"></asp:TextBox>
                        </td>
                        <td align="right">
                            配送送企业编号：
                        </td>
                        <td style="height: 24px; width: 304px;">
                            <asp:TextBox ID="textCompanyName_usercoder_ps" runat="server" InvertedComma="配送送企业编号"
                                Width="187px"></asp:TextBox>
                        </td>
                    </tr>
                    <tr>
                        <td align="right">
                            交易状态：
                        </td>
                        <td>
                            <asp:DropDownList ID="lstDealStatus" runat="server" Width="187px">
                            </asp:DropDownList>
                        </td>
                        <td>
                        </td>
                        <td>
                        </td>
                    </tr>
                    <tr>
                        <td align="right">
                            采购单号：
                        </td>
                        <td>
                            <asp:TextBox ID="TextBuyPlanId" runat="server" NumericOnly="采购单号" Width="187px"></asp:TextBox>
                        </td>
                        <td>
                        </td>
                        <td>
                            <input id="Submit2" class="button_80" name="btnSubmit1" style="" type="submit" value="查询"
                                onclick="javascript:return CheckForm1();" />
                        </td>
                    </tr>
                </table>
            </td>
        </tr>
        <tr>
            <td style="height: 20px">
                <asp:Label ID="Label1" runat="server" Text="Label" ForeColor="Red"></asp:Label>
        </tr>
    </table>
    <table>
        <tr>
            <td>
                <input type="submit" name="btn1" class="button_80" value="确认入库" onclick="javascript:return CheckForm();" />
                <input type="submit" name="btn_js" class="button_80" value="拒收" onclick="javascript:return CheckForm();" />
                <input id="but1" type="button" class="button_80" value="全选" onclick="javascript:SelectAll();" />
                <input id="but2" type="button" class="button_80" value="清空" onclick="javascript:ClearAll();" />
                <input id="but3" type="button" class="button_80" value="反选" onclick="javascript:CheckOthers();" />
                <asp:Button ID="Button1" runat="server" Text="打印" CssClass="button_80" OnClick="Button1_Click" />
            </td>
        </tr>
    </table>
    <div style="overflow: auto; width: 770px; height: 370px; border-width: 1px; border-color: #696969;
        border-style: none; cursor: default; display: inline; position: relative; float: left;
        white-space: nowrap; border: 1px">
        <asp:Label ID="Lablist" runat="server" Text=""></asp:Label>
    </div>
    <uc1:DbPageFlip ID="DbPageFlip1" runat="server" />
    <asp:GridView ID="GridView1" runat="server" Visible="false">
    </asp:GridView>
    <br />
</asp:Content>
